import request from '@/utils/request'

// 查询运管挂车备案列表
export function listRoadTrailer(query) {
  return request({
    url: '/bt/roadTrailer/list',
    method: 'get',
    params: query
  })
}

// 查询运管挂车备案详细
export function getRoadTrailer(id) {
  return request({
    url: '/bt/roadTrailer/getInfo/' + id,
    method: 'get'
  })
}

// 新增运管挂车备案
export function addRoadTrailer(data) {
  return request({
    url: '/bt/roadTrailer/add',
    method: 'post',
    data: data
  })
}

// 修改运管挂车备案
export function updateRoadTrailer(data) {
  return request({
    url: '/bt/roadTrailer/edit',
    method: 'post',
    data: data
  })
}

// 变更申报挂车备案
export function updateDeclRoadTrailer(data) {
  return request({
    url: '/bt/roadTrailer/editDecl',
    method: 'post',
    data: data
  })
}

// 删除运管挂车备案
export function delRoadTrailer(id) {
  return request({
    url: '/bt/roadTrailer/remove/' + id,
    method: 'get'
  })
}

// 导出运管挂车备案
export function exportRoadTrailer(query) {
  return request({
    url: '/bt/roadTrailer/export',
    method: 'get',
    params: query
  })
}

// 申报运管挂车备案
export function declRoadTrailer(id) {
  return request({
    url: '/bt/roadTrailer/decl/' + id,
    method: 'get'
  })
}
